package com.sso.core.ssoauth.service.impl;

import org.springframework.security.oauth2.provider.OAuth2Authentication;
import org.springframework.security.oauth2.provider.token.AuthenticationKeyGenerator;

import java.util.UUID;

/**
 * describe:
 *
 * @author 库琦
 * @date 2020/11/19/22:50
 */
public class RandomAuthenticationKeyGenerator implements AuthenticationKeyGenerator {
    @Override
    public String extractKey(OAuth2Authentication oAuth2Authentication) {
        return UUID.randomUUID().toString();
    }
}
